
		<cfobject type="component" component="usuario" name="oUsu">
		    <cfset oUsu.setnclaveu(#form.nclaveu#)>
			<cfset oUsu.setspasw(#form.spasw#)>

    		<cfset resu=oUsu.buscar()>
				<cfif resu EQ true>
                	<cflock scope="Session" type="exclusive" timeout="30">
                    	<cfset Session.firmado ="Si">
					</cflock>
                    
	        	    <cfset resu2=oUsu.tipo()>
                    
						<cfif resu2 EQ true>
                        
	                        <cfset Session.tipo ="Administrador">	
            			<cfelse>
                     <cflock scope="Session" type="exclusive" timeout="30">
	                        <cfset Session.tipo ="Cliente">                        
					</cflock>
		       	</cfif>
                <cfheader statuscode="301" statustext="Moved permanently">
				<cfheader name="Location" value="index.cfm">         
	            <cfelse>
		          <cfset sError ="Usuario no válido">
            </cfif>
